﻿@using ZDSoft.LMS.Domain;
@model Role

@{
    ViewBag.Title = "Details";
    Layout = "~/Views/Shared/_Layout.cshtml";
    <link href="@Url.Content("~/Content/Style/ViewPage.css")" rel="stylesheet" type="text/css" />
}

<h2>Details</h2>

<fieldset>
    <legend>Role</legend>

    <div class="display-label">RoleName</div>
    <div class="display-field">@Model.RoleName</div>

    <div class="display-label">IsActive</div>
    <div class="display-field">@Model.IsActive</div>

    <div class="display-label">Version</div>
    <div class="display-field">@Model.Version</div>
</fieldset>
<p>角色对应的功能：</p>
<table cellpadding="0" cellspacing="0" class="dataGrid">
    <tr>
        <th>
            角色名称
        </th>
        <th>
            显示顺序
        </th>
    </tr>
    @{
        if (Model.SystemFunctions == null || Model.SystemFunctions.Count == 0)
        {
            <tr>
                <td colspan="2">还未配置任何功能</td>
            </tr>
        }
        foreach (var item in Model.SystemFunctions)
        {
            <tr>
                <td>@item.SystemFunctionName</td>
                <td>@item.Idx</td>
            </tr>
        }
    }
</table>
<p>
    @Html.ActionLink("Edit", "Edit", new { id = Model.ID }) |
    @Html.ActionLink("Back to List", "Index")
</p>

